const {
  override,
  fixBabelImports,
  addPostcssPlugins,
} = require("customize-cra");

const postCssPxtoRem = require("postcss-pxtorem");

module.exports = override(
  fixBabelImports("import", {
    libraryName: "antd-mobile",
    style: "css",
  }),
  addPostcssPlugins([
    postCssPxtoRem({
      //html的font-size字体大小
      rootValue: 37.5,

      //所有样式属性都参与px转rem
      propList: ["*"],
    }),
  ])
);
